<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>

<div class="spalistw730">
	<div class="spaw730nav">
		<p class="sHB00 fl">Ta的好友</p>
	</div>
	<div class="spalisdiv">
		<c:set var="rosterSize" value="0"></c:set>
		<c:if test="${not empty rosterGroups}">
			<c:forEach var="rosterGroup" items="${rosterGroups}" varStatus="status">
				<c:forEach var="roster" items="${rosterGroup.groupUsers}" varStatus="gustatus">
					<c:set var="rosterSize" value="1"></c:set>
					<dl class="spalistfriedl">
						<dt>
							<c:set var="avatarpath"><ms:user type="avatar" link="false" userid="${roster.userid}" nickname="" style=""/></c:set>
							<img style="width:48px;height:48px;" src="${ctx}/${avatarpath}">
						</dt>
						<dd>
							<p>
								<a class="lB66" target="_blank" href="<c:url value='/space/index.do?usr=${roster.userid}'/>">
									<c:out value="${roster.nickname}"/>
								</a>
							</p>
							<p class="s666">
								积分数:
								<span class="sf00">
									<ms:user userid="${roster.userid}" type="score"></ms:user>
								</span>
							</p>
							<p class="spalistfriedlp">
								<a href="javascript:writeWords(${roster.userid})">发消息</a>
								<c:set var="roster_relation"><ms:roster sender="${userid}" receiver="${roster.userid}"/></c:set>
								<c:if test="${roster_relation==0 || roster_relation==3}">
									<a style="marging-left:5px;" href="javascript:requestFriend(${roster.userid});">加为好友</a>
								</c:if>
							</p>
						</dd>
					</dl>
				</c:forEach>
			</c:forEach>
		</c:if>
		<c:if test="${rosterSize == 0}">暂无</c:if>
	</div>
	<div class="pagediv martop10 tc">
	</div>
</div>
<tiles:insertDefinition name="html.space.content.right.viewer">
	<tiles:putAttribute name="userInfo" value="${userInfo}"></tiles:putAttribute>
</tiles:insertDefinition>